package com.tangyuan.user.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.tangyuan.common.result.Result;
import com.tangyuan.model.User;
import com.tangyuan.model.UserConcern;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public interface UserConcernService extends IService<UserConcern> {

    void cancelConcernUser(Long userId, Long concernUserId);

    Result addConcern(User user, Long concernUserId,Integer type);

    List<UserConcern> selectUserConcernList(Long userId, Long concernUserId);

    /**
     * @param concernUserId 被关注人
     * @param type 关注方式
     * @param id 关注ID (视频ID,百家ID,直播ID)
     * @return 关注数量
     */
    Long getLiveConcernNum(Long concernUserId, Integer type,Long id);

    Result<Boolean> isConcern(Long userId, Long concernUserId);
}
